import { Input } from "antd";
import { useEffect, RefObject, createRef } from "react";

const { Search } = Input;
function Mask(props) {
  const inpdom: RefObject<Input> = createRef();
  useEffect(() => {
    inpdom.current?.focus();
  }, []);
  return (
    <div className="mask">
      <div className="maskdiv">
        <h2>
          <span>文章搜索</span>{" "}
          <span onClick={() => props.setfalg(false)}> x</span>
        </h2>
        <Search
          placeholder="input search loading default"
          ref={inpdom}
          className="seach"
        />
        <div className="seachdiv">
          {" "}
          <span>暂无数据</span>{" "}
        </div>
      </div>
    </div>
  );
}
export default Mask;
